<script setup>
import "@/Widgets/widgets.css";
import initViewer from "@/cesium/initViewer.js";
import MousePositon from "@/cesium/mousePosition.js";
import CesiumNavigation from "cesium-navigation-es6";
import modifyMap from "@/cesium/modifyMap.js";
import modifyBulid from "@/cesium/modifyBulid.js";
import LightCone from "@/cesium/lightCone.js";
import RectFyLIight from "@/cesium/RectFyLight.js";
import RoadsLine from "@/cesium/roadsLine.js";
import RadarLight from "@/cesium/radarLight.js";
import HexaGonLight from "@/cesium/hexagonLight.js";
import WallLight from "@/cesium/wallLight.js";
import Particle from "@/cesium/particle.js";
import { onMounted } from "vue";

onMounted(() => {
  const viewer = initViewer();

  new MousePositon(viewer);
  // 罗盘配置
  const options = {
    // 启用罗盘
    enableCompass: true,
    // 启用缩放
    enableZoomControls: true,
    // 图示距离
    enableDistanceLegend: true,
    // 外环拖动
    enableCompassOuterRing: true,
  };
  new CesiumNavigation(viewer, options);
  modifyMap(viewer);
  modifyBulid(viewer);
  new LightCone(viewer); // 添加椎体
  new RectFyLIight(viewer);
  new RoadsLine(viewer);
  new RadarLight(viewer);
  new HexaGonLight(viewer);
  new WallLight(viewer);
  new Particle(viewer);
});
</script>

<template>
  <div id="cesium-container" class="cesium-container"></div>
</template>
